import 'package:flutter/cupertino.dart';
import 'package:thinking/entity/_.dart';
import 'package:thinking/utils/_.dart';
import 'package:thinking/config/_.dart';

class TopicClassLeft extends StatelessWidget{

  final TagClassIndex topicClass;
  final double topicClassWidth;
  final Color backgroundColor;
  final Color textColor;
  final bool isClick;
  final int id;
  TopicClassLeft({required this.topicClass,required this.topicClassWidth,required this.backgroundColor,required this.textColor,required this.isClick,required this.id});

  @override
  Widget build(BuildContext context) {
   return Container(
     padding: EdgeInsets.only(top: 5,bottom: 5),
     height: Screen.setHeight(55),
     width: Screen.setWidth(topicClassWidth),
     color: isClick?backgroundColor:null,
     child: Column(
       mainAxisAlignment: MainAxisAlignment.center,
       children: [
         Text(topicClass.tagClassName!,style: TextStyle(fontSize: 15,color:textColor,fontWeight: FontWeight.bold ),),
         Visibility(child: SizedBox(height: 5,),visible: id>2,),
         Visibility(child: Text(topicClass.tagClassNum!.toString(),style: TextStyle(fontSize: 13,color:isClick?textColor:ColorConfig.TextColor ),),visible: id>2,)
       ],
     ),
   );
  }

}